﻿<?php
 
 
 
defined("_VALID_ACCESS") || die('Direct access forbidden');
 
 
 
class SCTV_StatusTodoInstall extends ModuleInstall {
 
    public function install() { // Here you can place the installation process for the module
 		Base_ThemeCommon::install_default_theme($this->get_type());
		
		$fields = array(
			array('name'=>_M('Status'), 'type'=>'commondata', 'param'=>array('order_by_key'=>true,'SCTV/Requirement/Status'), 'required'=>true, 'visible'=>true),
			array('name'=>_M('Todo'), 'type'=>'commondata', 'param'=>array('order_by_key'=>true,'SCTV/Requirement/Todo'), 'required'=>true, 'visible'=>true)
		);
		
		Utils_RecordBrowserCommon::install_new_recordset('SCTV_StatusTodo', $fields);
		Utils_RecordBrowserCommon::set_caption('SCTV_StatusTodo', _M('StatusTodo'));
		Utils_RecordBrowserCommon::add_default_access('SCTV_StatusTodo');
	
		return true; // Return true on success and false on failure
    }
 
    public function uninstall() { // Here you can place uninstallation process for the module
		Base_ThemeCommon::uninstall_default_theme($this->get_type());
		Utils_RecordBrowserCommon::uninstall_recordset('SCTV_StatusTodo');
		return true;
    }
 
    public function info() { // Returns basic information about the module which will be available in the epesi Main Setup
 
        return array( 'Author'=>'Pham Huu Le Quoc Phuc',
            'License'=>'SCTV',
                     'Description'=>'StatusTodo');
 
    }
 
    public function simple_setup() { // Indicates if this module should be visible on the module list in Main Setup's simple view
 
        return array('package' => __('StatusTodo'), 'version'=>'1.0'); // - now the module will be visible as "HelloWorld" in simple_view
 
    }
 
    public function requires($v) { // Returns list of modules and their versions, that are required to run this module
 
        return array();
 
    }
 
    public function version() { // Return version name of the module
 
        return array('1.0');
 
    }
}
 
?>